package test3_21.demo01;

/*
MyDate类包含:
	private成员变量month,day,year；
	toDateString()方法返回日期对应的字符串：xxxx年xx月xx日

 */
public class MyDate {

    private int year;
    private int month;
    private int day;

    public MyDate(){};

    public MyDate(int year, int month, int day) {
        this.year = year;
        this.month = month;
        this.day = day;
    }

    public String toDateString() {
        String bir = this.year + "年" + this.month + "月" + this.day + "日";
        return bir;
    }

    public int getMonth() {
        return month;
    }
}
